package sectorCrack.utils;

import java.io.BufferedWriter;
import java.io.File;
import java.io.FileWriter;
import java.io.IOException;
import java.util.ArrayList;

import sectorCrack.bean.Dat;

public class TextFileCreator {

	public static void createFile(ArrayList<Dat> data, String filename) throws IOException {
		File outFile = new File(filename);
		BufferedWriter bw = new BufferedWriter(new FileWriter(outFile));
		for (Dat dat : data) {
			bw.append(dat.toString()+"\n");
		}

		bw.close();
	}

}
